import Snippet from '~/components/snippet'
import Caption from '~/components/text/caption'
import { InlineCode } from '~/components/text/code'
import Note from '~/components/text/note'
import Link from '~/components/text/link'

export const meta = {
  editUrl: 'pages/docs/now-cli/now-cli-mdx/commands/remove.mdx',
  lastEdited: '2019-10-22T21:47:59.000Z'
}

## Remove

The `now remove` command, which can be shortened to `now rm`, is used to remove deployments either by ID or for a specific project.

<Note type="warning">
  This command is for <b>advanced use only</b>. Although unlikely you will be
  required to, you can remove deployments from the Project Overview page on the
  ZEIT Dashboard.
</Note>

### Basic Usage

<Snippet dark text="now remove [deployment-url]" />
<Caption>Using the <InlineCode>now remove</InlineCode> command to remove a deployment from the ZEIT Now platform.</Caption>

### Extended Usage

<Snippet dark text="now remove [deployment-url-1 deployment-url-2]" />
<Caption>Using the <InlineCode>now remove</InlineCode> command to remove multiple deployments from the ZEIT Now platform.</Caption>

<Snippet dark text="now remove [project-name]" />
<Caption>Using the <InlineCode>now remove</InlineCode> command to remove all deployments for a project from the ZEIT Now platform.</Caption>

<Note type="warning">
  By using the <Link href="/docs/v2/platform/projects/">project name</Link>, the
  entire project will be removed from the account unless the{' '}
  <InlineCode>--safe</InlineCode> is used.
</Note>

### Global Options

The following [global options](#options) can be passed when using the `now remove` command:

- `--debug`
- `--global-config`
- `--help`
- `--local-config`
- `--scope`
- `--token`

For more information on global options and their usage, refer to the [options section](#options).

### Unique Options

These are options that only apply to the `now remove` command, therefore, more information is provided.

#### Safe

The `--safe` option, shorthand `-s`, can be used to skip the removal of deployments with an active preview URL or production domain when a project is provided as the parameter.

##### Usage Example

<Snippet dark text="now remove my-project --safe" />
<Caption>Using the <InlineCode>now remove</InlineCode> command with the <InlineCode>--safe</InlineCode> option.</Caption>

#### Yes

The `--yes` option, shorthand `-y`, can be used to skip the confirmation step for a deployment or project removal.

##### Usage Example

<Snippet dark text="now remove my-deployment.com --yes" />
<Caption>Using the <InlineCode>now remove</InlineCode> command with the <InlineCode>--yes</InlineCode> option.</Caption>
